<template>
    <div>
        <table>
            <td>
                <img :src="add.img" width="700" height="500" v-if="add.img != ''">
            </td>
        </table>
    </div>
</template>

<script setup lang="ts">
import axios from 'axios';
import { ref, reactive, onMounted } from "vue";
import moment from 'moment';
import { useStore } from '@/stores/kll';
import { useRouter, useRoute } from "vue-router";
const router = useRouter();
const route = useRoute();
const a = useStore();

let add: any = reactive(
    {
        "id": route.query.id,
        "name": "",
        "money": "",
        "img": "",
        "sname": "",
        "yao": [],
        "time1": "",
        "time2": "",
        "style": true,
        "isdel": true,

    }
)
onMounted(()=>{
    ft();
})
const ft = () => {
    axios({
        url: 'https://localhost:7298/api/Emp/ft',
        method: 'get',
        params: {
            id: route.query.id
        }
    })
        .then(res => {
            console.log(res);
            Object.assign(add, res.data);
        
        })
        .catch(err => {
            console.log(err);

        })
}
</script>

<style scoped>

</style>